<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<style type="text/css">
* {
	margin: 0;
	padding: 0;
}

#all {
	width: 400px;
	/* 	height: 200px; */
	margin: 100px auto;
	background-color: gray;
	border: 1px solid gray;
	border-radius: 5px;
	border-collapse: collapse;
}

#first {
	padding: 5px;
}

#first img {
	border: 0px;
	width: 16px;
	height: 16px;
	display:none;
}

#first a {
	color:white;

}
#second {
	background-color: #ffffff;
	margin: 0px 2px;
}

#third {
	/* 	background-color: #8cded8; */
	text-align: right;
	/* 	margin-bottom: 10px; */
	padding: 5px;
}

#third a {
	border-radius: 3px;
	border: 1px solid gray;
	text-decoration: none;
	color: white;
}
</style>
</head>
<body>
	<div id="all">
		<div id="first">
			<div style="float: left">
				<img alt="" src="images/lock.png"> <span>欢迎进入登录窗口</span>
			</div>

			<div id="register" style="float: right">
				<a href="final-register.jsp"> <img alt=""
					src="images/rabbit2.png"> <span>注册</span>
				</a>
			</div>
			<div style="clear: both"></div>
		</div>

		<div id="second">
			<form name="form1" method="get" action="">
				<table>
					<tr>
						<td>
							<table>
								<tr>
									<td>用户</td>
									<td><input type="text" id="userno" name="userno"
										value="请输入用户号"></td>
								</tr>
								<tr>
									<td>密码</td>
									<td><input type="text" id="userpwd" name="userpwd"
										value="请输入密码"></td>

								</tr>
								<tr>
									<td colspan="2"><input type="radio" name="userident"
										value="管理员" checked="checked">管理员 <input type="radio"
										name="userident" value="普通用户">普通用户</td>

								</tr>
							</table>
						</td>
						<td><img alt="" src="images/pp.png"></td>
					</tr>
				</table>
			</form>

		</div>

		<div id="third">
			<!-- 以下#与javascript:void(0)都表示空链接，一般推荐使用javascript-->
 			<!--<a href="#" onclick="logincheck();return false;">  -->
			<a href="javascript:void(0)" onclick="logincheck();return false;"> 
				<img alt="" src="images/ok.png">
				登录
			</a>
		</div>

	</div>
	
	<script type="text/javascript">
	function  logincheck(){
		var address=["final-mainadmin.jsp","final-main.jsp"];		
		var ident=form1.userident;//这里原写成userindent，运行不出来
		for(var i=0;i<ident.length;i++){
			if(ident[i].checked==true){
				window.location.href=address[i];
				//window.location.href=address[i]+"?userno="+form1.userno.value;
			}
		}
		//return false;目的是去除默读的跳转，也可以在html中写
	}
	</script>

</body>
</html>
